package com.xyd.bean;

import java.io.Serializable;

public class Product implements Serializable {
    private int id;
    private String name;
    private String desc;
    private double price;
    //商品库存
    private int stock;
    private ParentCategory parentCategory;
    private ChildCategory childCategory;
    //上传的文件名
    private String filename;

    public Product(String name, String desc, double price, int stock, ParentCategory parentCategory, ChildCategory childCategory, String filename) {
        this.name = name;
        this.desc = desc;
        this.price = price;
        this.stock = stock;
        this.parentCategory = parentCategory;
        this.childCategory = childCategory;
        this.filename = filename;
    }

    public Product() {
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

    public double getPrice() {
        return price;
    }

    public void setPrice(double price) {
        this.price = price;
    }

    public int getStock() {
        return stock;
    }

    public void setStock(int stock) {
        this.stock = stock;
    }

    public ParentCategory getParentCategory() {
        return parentCategory;
    }

    public void setParentCategory(ParentCategory parentCategory) {
        this.parentCategory = parentCategory;
    }

    public ChildCategory getChildCategory() {
        return childCategory;
    }

    public void setChildCategory(ChildCategory childCategory) {
        this.childCategory = childCategory;
    }

    public String getFilename() {
        return filename;
    }

    public void setFilename(String filename) {
        this.filename = filename;
    }
}